import { createSlice } from '@reduxjs/toolkit'

const initialState = {
  checked: false
}

const checkboxSlice = createSlice({
  name: 'checkbox',
  initialState,
  reducers: {
    setChecked(state, action) {
        state.checked = action.payload
    }
  },
})

export const { setChecked } = checkboxSlice.actions

export default checkboxSlice.reducer